﻿$(function(){
	$("#main_page_store").click(function(){
		$.ajax({
			type: "POST",
			url: "http://yx.fxtourong.com/V1/Member/hasCreateStore",
			data: {
				token : localStorage.getItem("token")
			},
			dataType: "json",
			success: function(data) {
				console.log(data);
				var code = data.code;
				console.log(code);
				if(code == "1") {
					console.log("已经创建店铺");
					location.href = "my_store.html";
				} else {
					console.log("没有创建店铺");
					location.href = "createStore.html";
				}
			}
		});
	});
});